<?php
// 全局引用
require_once 'include/Json.class.php';
require_once 'include/Dbtool.class.php';
require_once 'include/Model.class.php';
require_once "include/WebDispatcher.class.php";

require 'config/index.config.php';

// 响应设置
header('Access-Control-Allow-Origin:*');
header('Access-Control-Allow-Methods:POST');//表示只允许POST请求
header('Access-Control-Allow-Headers:x-requested-with, content-type');
header('Content-Type:Application/JSON');

// if ($_SERVER['REQUEST_METHOD'] == 'GET') {
//     header('HTTP/1.1 403 Forbidden');
//     exit;
// }

// 请求分发
WebDispatcher::create();

